package com.healthy.controller.pc;

import javax.servlet.http.HttpServletRequest;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;

import com.alibaba.fastjson.JSONObject;
import com.healthy.service.YgAdminsService;

/**
 * @author Maple.Chen
 * @date 2020年6月17日
 * @description <p>管理员相关功能-控制器</p>
 */
@RestController
public class YgAdminController {
	
	@Autowired
	private YgAdminsService ygAdminsService;
	
	// Excel表格数据入库
	@RequestMapping(value = "", method = RequestMethod.GET, produces = "application/json;charset=UTF-8")
	public JSONObject test1(@RequestParam("upfile") MultipartFile file, HttpServletRequest request){
		JSONObject json = ygAdminsService.ExcelImport(file, request);
		return json;
	}
	
	
	
}
